package com.swust.exam.pojo;

import java.io.Serializable;
import java.util.Date;

public class Exam implements Serializable {
    private Integer examId;

    private Integer courseId;

    private Integer classId;

    private String examName;

    private Date examTime;

    private String examPlace;

    private Integer bankId;

    private static final long serialVersionUID = 1L;

    public Integer getExamId() {
		return examId;
	}

	public void setExamId(Integer examId) {
		this.examId = examId;
	}

	public Integer getCourseId() {
		return courseId;
	}

	public void setCourseId(Integer courseId) {
		this.courseId = courseId;
	}

	public Integer getClassId() {
		return classId;
	}

	public void setClassId(Integer classId) {
		this.classId = classId;
	}

	public String getExamName() {
		return examName;
	}

	public void setExamName(String examName) {
		this.examName = examName;
	}

	public Date getExamTime() {
		return examTime;
	}

	public void setExamTime(Date examTime) {
		this.examTime = examTime;
	}

	public String getExamPlace() {
		return examPlace;
	}

	public void setExamPlace(String examPlace) {
		this.examPlace = examPlace;
	}

	public Integer getBankId() {
		return bankId;
	}

	public void setBankId(Integer bankId) {
		this.bankId = bankId;
	}

	@Override
	public int hashCode() {
		final int prime = 31;
		int result = 1;
		result = prime * result + ((bankId == null) ? 0 : bankId.hashCode());
		result = prime * result + ((classId == null) ? 0 : classId.hashCode());
		result = prime * result + ((courseId == null) ? 0 : courseId.hashCode());
		result = prime * result + ((examId == null) ? 0 : examId.hashCode());
		result = prime * result + ((examName == null) ? 0 : examName.hashCode());
		result = prime * result + ((examPlace == null) ? 0 : examPlace.hashCode());
		result = prime * result + ((examTime == null) ? 0 : examTime.hashCode());
		return result;
	}

	@Override
	public boolean equals(Object obj) {
		if (this == obj)
			return true;
		if (obj == null)
			return false;
		if (getClass() != obj.getClass())
			return false;
		Exam other = (Exam) obj;
		if (bankId == null) {
			if (other.bankId != null)
				return false;
		} else if (!bankId.equals(other.bankId))
			return false;
		if (classId == null) {
			if (other.classId != null)
				return false;
		} else if (!classId.equals(other.classId))
			return false;
		if (courseId == null) {
			if (other.courseId != null)
				return false;
		} else if (!courseId.equals(other.courseId))
			return false;
		if (examId == null) {
			if (other.examId != null)
				return false;
		} else if (!examId.equals(other.examId))
			return false;
		if (examName == null) {
			if (other.examName != null)
				return false;
		} else if (!examName.equals(other.examName))
			return false;
		if (examPlace == null) {
			if (other.examPlace != null)
				return false;
		} else if (!examPlace.equals(other.examPlace))
			return false;
		if (examTime == null) {
			if (other.examTime != null)
				return false;
		} else if (!examTime.equals(other.examTime))
			return false;
		return true;
	}

	@Override
	public String toString() {
		return "Exam [examId=" + examId + ", courseId=" + courseId + ", classId=" + classId + ", examName=" + examName
				+ ", examTime=" + examTime + ", examPlace=" + examPlace + ", bankId=" + bankId + "]";
	}

}

    